package ar.com.gestion.dao;

import org.springframework.jdbc.core.JdbcTemplate;

import ar.com.gestion.dominio.Fiado;

public class FiadoDAO {

	private JdbcTemplate jdbcTemplate;

	
	public int saveFiado(Fiado fiado){
		String sql = "insert into fiado (monto,id_ventas,id_pagos) values (?,?,?)";
		return jdbcTemplate.update(sql,new Object[]{fiado.getMonto(),fiado.getId_venta(),fiado.getId_pago()});
		
	}
	
	
	
	
	public JdbcTemplate getJdbcTemplate() {
		return jdbcTemplate;
	}

	public void setJdbcTemplate(JdbcTemplate jdbcTemplate) {
		this.jdbcTemplate = jdbcTemplate;
	}
	
	
	
}
